package cn.iocoder.yudao.module.game.dal.mysql.gameManufacturer;

import java.util.*;

import cn.iocoder.yudao.framework.common.pojo.PageResult;
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.yudao.module.game.dal.dataobject.gameManufacturer.GameManufacturerDO;
import org.apache.ibatis.annotations.Mapper;
import cn.iocoder.yudao.module.game.controller.admin.gameManufacturer.vo.*;

/**
 * 游戏厂商概况 Mapper
 *
 * @author 芋道源码
 */
@Mapper
public interface GameManufacturerMapper extends BaseMapperX<GameManufacturerDO> {

    default PageResult<GameManufacturerDO> selectPage(GameManufacturerPageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<GameManufacturerDO>()
                .eqIfPresent(GameManufacturerDO::getGameChannel, reqVO.getGameChannel())
                .eqIfPresent(GameManufacturerDO::getCoinBet, reqVO.getCoinBet())
                .eqIfPresent(GameManufacturerDO::getWinCoin, reqVO.getWinCoin())
                .eqIfPresent(GameManufacturerDO::getProfitAndLoss, reqVO.getProfitAndLoss())
                .eqIfPresent(GameManufacturerDO::getTotalBetPoints, reqVO.getTotalBetPoints())
                .betweenIfPresent(GameManufacturerDO::getCreateTime, reqVO.getCreateTime())
                .orderByDesc(GameManufacturerDO::getId));
    }

}